<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
	</head>
	<body>
		<div id="num">15</div>
		
		<script type="text/javascript">
			//1. 输入一个秒数, 然后开始倒计时到0秒, 最多10000秒。
			let i = 15;
			let timer = window.setInterval(() => {
				document.getElementById("num").innerHTML = i;
				i--;
				if (i < 0) {
					window.clearInterval(timer);
				}
			}, 1000);
	</script>
	</body>
</html>
